tar xf ${DOWNLOADDIR}/glibc-2.42.tar.xz -C ${BUILDDIR}
pushd ${BUILDDIR}/glibc-2.42
    patch -Np1 -i ${DOWNLOADDIR}/glibc-2.42-fhs-1.patch
    mkdir -v build-64
    pushd build-64
        BUILD_CC="gcc" CC="${CROSS_TARGET}-gcc ${BUILD64}" \
        CXX="${CROSS_TARGET}-gcc ${BUILD64}" \
        AR="${CROSS_TARGET}-ar" RANLIB="${CROSS_TARGET}-ranlib" \
        ../configure --prefix=/usr --host=${CROSS_TARGET} --build=${CROSS_HOST} \
	                 --libdir=/usr/lib64 --libexecdir=/usr/lib64/glibc \
	                 --with-binutils=${SYSDIR}/cross-tools/bin \
	                 --with-headers=${SYSDIR}/sysroot/usr/include \
	                 --enable-stack-protector=strong --enable-add-ons \
	                 --disable-werror --disable-nscd libc_cv_slibdir=/usr/lib64 \
	                 --enable-kernel=5.19.0
		make ${JOBS}
		make DESTDIR=${SYSDIR}/sysroot install
	popd
	mkdir -v build-locale
	pushd build-locale
		../configure --prefix=/usr --libdir=/usr/lib64 --libexecdir=/usr/lib64/glibc \
	                 --enable-stack-protector=strong --enable-add-ons \
	                 --disable-werror libc_cv_slibdir=/usr/lib64
		make ${JOBS}
		make DESTDIR=${SYSDIR}/sysroot localedata/install-locales
	popd
popd

